When an unmount operation fails, the only feedback given currently
is an exception on stderr. Use the infoBar to display an error
message and allow the user to retry the operation.
https://bugzilla.gnome.org/show_bug.cgi?id=612200
},
_removeFinish: function(o, res, data) {
- this._mount.unmount_finish(res);
+ try {
+ this._mount.unmount_finish(res);
+ } catch (e) {
+ let message = _("Failed to unmount '%s'").format(o.get_name());
+ Main.overview.infoBar.setMessage(message,
+ Lang.bind(this, this.remove),
+ _("Retry"));
+ }
}
};